//
//  KLSGPlayerView.m
//  KaoLaShiGuangFM
//
//  Created by lanou3g on 15/11/7.
//  Copyright © 2015年 com.lanou3g. All rights reserved.
//

#import "KLSGPlayerView.h"

@implementation KLSGPlayerView

// 其中playerView继承自UIView，不过重写了set和get方法，用于将player添加至playerView的AVPlayerLayer中，这样才能顺利将视频显示出来

+ (Class)layerClass
{
    return [AVPlayerLayer class];
}

- (AVPlayer *)player
{
    return [(AVPlayerLayer *)[self layer] player];
}

- (void)setPlayer:(AVPlayer *)player
{
    return [(AVPlayerLayer *)[self layer] setPlayer:player];
}


@end
